home *** CD-ROM | disk | FTP | other *** search
/ IRIX Base Documentation 2001 May / SGI IRIX Base Documentation 2001 May.iso / usr / share / catman / p_man / cat1 / bison.z / bison
Encoding:
Text File  |  1998-10-20  |  12.7 KB  |  265 lines

  1.  
  2.  
  3.  
  4.      BBBBIIIISSSSOOOONNNN((((1111))))              UUUUNNNNIIIIXXXX SSSSyyyysssstttteeeemmmm VVVV ((((llllooooccccaaaallll))))              BBBBIIIISSSSOOOONNNN((((1111))))
  5.  
  6.  
  7.  
  8.      NNNNAAAAMMMMEEEE
  9.           bison - GNU Project parser generator (yacc replacement)
  10.  
  11.      SSSSYYYYNNNNOOOOPPPPSSSSIIIISSSS
  12.           bbbbiiiissssoooonnnn [ ----bbbb _f_i_l_e-_p_r_e_f_i_x ] [ --------ffffiiiilllleeee----pppprrrreeeeffffiiiixxxx====_f_i_l_e-_p_r_e_f_i_x ] [ ----dddd
  13.           ] [ --------ddddeeeeffffiiiinnnneeeessss ] [ ----kkkk ] [ --------ttttooookkkkeeeennnn----ttttaaaabbbblllleeee ] [ ----llll ] [ --------nnnnoooo----lllliiiinnnneeeessss
  14.           ] [ ----nnnn ] [ --------nnnnoooo----ppppaaaarrrrsssseeeerrrr ] [ ----oooo _o_u_t_f_i_l_e ] [ --------oooouuuuttttppppuuuutttt----
  15.           ffffiiiilllleeee====_o_u_t_f_i_l_e ] [ ----pppp _p_r_e_f_i_x ] [ --------nnnnaaaammmmeeee----pppprrrreeeeffffiiiixxxx====_p_r_e_f_i_x ] [ ----rrrr ]
  16.           [ --------rrrraaaawwww ] [ ----tttt ] [ --------ddddeeeebbbbuuuugggg ] [ ----vvvv ] [ --------vvvveeeerrrrbbbboooosssseeee ] [ ----VVVV ] [
  17.           --------vvvveeeerrrrssssiiiioooonnnn ] [ ----yyyy ] [ --------yyyyaaaacccccccc ] [ ----hhhh ] [ --------hhhheeeellllpppp ] [ --------ffffiiiixxxxeeeedddd----
  18.           oooouuuuttttppppuuuutttt----ffffiiiilllleeeessss ] file
  19.  
  20.      DDDDEEEESSSSCCCCRRRRIIIIPPPPTTTTIIIIOOOONNNN
  21.           _B_i_s_o_n is a parser generator in the style of _y_a_c_c(1).  It
  22.           should be upwardly compatible with input files designed for
  23.           _y_a_c_c.
  24.  
  25.           Input files should follow the _y_a_c_c convention of ending in
  26.           ....yyyy.  Unlike _y_a_c_c, the generated files do not have fixed
  27.           names, but instead use the prefix of the input file.  For
  28.           instance, a grammar description file named ppppaaaarrrrsssseeee....yyyy would
  29.           produce the generated parser in a file named ppppaaaarrrrsssseeee....ttttaaaabbbb....cccc,
  30.           instead of _y_a_c_c's yyyy....ttttaaaabbbb....cccc.
  31.  
  32.           This description of the options that can be given to _b_i_s_o_n
  33.           is adapted from the node IIIInnnnvvvvooooccccaaaattttiiiioooonnnn in the bbbbiiiissssoooonnnn....tttteeeexxxxiiiinnnnffffoooo
  34.           manual, which should be taken as authoritative.
  35.  
  36.           _B_i_s_o_n supports both traditional single-letter options and
  37.           mnemonic long option names.  Long option names are indicated
  38.           with -------- instead of ----.  Abbreviations for option names are
  39.           allowed as long as they are unique.  When a long option
  40.           takes an argument, like --------ffffiiiilllleeee----pppprrrreeeeffffiiiixxxx, connect the option
  41.           name and the argument with ====.
  42.  
  43.         OOOOPPPPTTTTIIIIOOOONNNNSSSS
  44.           ----bbbb _f_i_l_e-_p_r_e_f_i_x
  45.           --------ffffiiiilllleeee----pppprrrreeeeffffiiiixxxx====_f_i_l_e-_p_r_e_f_i_x
  46.                Specify a prefix to use for all _b_i_s_o_n output file
  47.                names.  The names are chosen as if the input file were
  48.                named _f_i_l_e-_p_r_e_f_i_x....cccc.
  49.  
  50.           ----dddd
  51.           --------ddddeeeeffffiiiinnnneeeessss
  52.                Write an extra output file containing macro definitions
  53.                for the token type names defined in the grammar and the
  54.                semantic value type YYYYYYYYSSSSTTTTYYYYPPPPEEEE, as well as a few eeeexxxxtttteeeerrrrnnnn
  55.                variable declarations.
  56.  
  57.                If the parser output file is named _n_a_m_e....cccc then this
  58.                file is named _n_a_m_e....hhhh.
  59.  
  60.  
  61.  
  62.  
  63.      Page 1                                          (printed 4/30/98)
  64.  
  65.  
  66.  
  67.  
  68.  
  69.  
  70.      BBBBIIIISSSSOOOONNNN((((1111))))              UUUUNNNNIIIIXXXX SSSSyyyysssstttteeeemmmm VVVV ((((llllooooccccaaaallll))))              BBBBIIIISSSSOOOONNNN((((1111))))
  71.  
  72.  
  73.  
  74.                This output file is essential if you wish to put the
  75.                definition of yyyyyyyylllleeeexxxx in a separate source file, because
  76.                yyyyyyyylllleeeexxxx needs to be able to refer to token type codes and
  77.                the variable yyyyyyyyllllvvvvaaaallll.
  78.  
  79.           ----rrrr
  80.           --------rrrraaaawwww
  81.                The token numbers in the _n_a_m_e....hhhh file are usually the
  82.                Yacc compatible translations.  If this switch is
  83.                specified, Bison token numbers are output instead.
  84.                (Yacc numbers start at 257 except for single character
  85.                tokens;  Bison assigns token numbers sequentially for
  86.                all tokens starting at 3.)
  87.  
  88.           ----kkkk
  89.           --------ttttooookkkkeeeennnn----ttttaaaabbbblllleeee
  90.                This switch causes the _n_a_m_e....ttttaaaabbbb....cccc output to include a
  91.                list of token names in order by their token numbers;
  92.                this is defined in the array _y_y_t_n_a_m_e.  Also generated
  93.                are #defines for _Y_Y_N_T_O_K_E_N_S, _Y_Y_N_N_T_S, _Y_Y_N_R_U_L_E_S, and
  94.                _Y_Y_N_S_T_A_T_E_S.
  95.  
  96.           ----llll
  97.           --------nnnnoooo----lllliiiinnnneeeessss
  98.                Don't put any ####lllliiiinnnneeee preprocessor commands in the parser
  99.                file.  Ordinarily _b_i_s_o_n puts them in the parser file so
  100.                that the C compiler and debuggers will associate errors
  101.                with your source file, the grammar file.  This option
  102.                causes them to associate errors with the parser file,
  103.                treating it an independent source file in its own
  104.                right.
  105.  
  106.           ----nnnn
  107.           --------nnnnoooo----ppppaaaarrrrsssseeeerrrr
  108.                Do not generate the parser code into the output;
  109.                generate only declarations.  The generated _n_a_m_e....ttttaaaabbbb....cccc
  110.                file will have only constant declarations.  In
  111.                addition, a _n_a_m_e....aaaacccctttt file is generated containing a
  112.                switch statement body containing all the translated
  113.                actions.
  114.  
  115.           ----oooo _o_u_t_f_i_l_e
  116.           --------oooouuuuttttppppuuuutttt----ffffiiiilllleeee====_o_u_t_f_i_l_e
  117.                Specify the name _o_u_t_f_i_l_e for the parser file.
  118.  
  119.                The other output files' names are constructed from
  120.                _o_u_t_f_i_l_e as described under the ----vvvv and ----dddd switches.
  121.  
  122.           ----pppp _p_r_e_f_i_x
  123.           --------nnnnaaaammmmeeee----pppprrrreeeeffffiiiixxxx====_p_r_e_f_i_x
  124.                Rename the external symbols used in the parser so that
  125.                they start with _p_r_e_f_i_x instead of yyyyyyyy.  The precise list
  126.  
  127.  
  128.  
  129.      Page 2                                          (printed 4/30/98)
  130.  
  131.  
  132.  
  133.  
  134.  
  135.  
  136.      BBBBIIIISSSSOOOONNNN((((1111))))              UUUUNNNNIIIIXXXX SSSSyyyysssstttteeeemmmm VVVV ((((llllooooccccaaaallll))))              BBBBIIIISSSSOOOONNNN((((1111))))
  137.  
  138.  
  139.  
  140.                of symbols renamed is yyyyyyyyppppaaaarrrrsssseeee, yyyyyyyylllleeeexxxx, yyyyyyyyeeeerrrrrrrroooorrrr, yyyyyyyyllllvvvvaaaallll,
  141.                yyyyyyyycccchhhhaaaarrrr, and yyyyyyyyddddeeeebbbbuuuugggg.
  142.  
  143.                For example, if you use ----pppp cccc, the names become ccccppppaaaarrrrsssseeee,
  144.                cccclllleeeexxxx, and so on.
  145.  
  146.           ----tttt
  147.           --------ddddeeeebbbbuuuugggg
  148.                Output a definition of the macro YYYYYYYYDDDDEEEEBBBBUUUUGGGG into the
  149.                parser file, so that the debugging facilities are
  150.                compiled.
  151.  
  152.           ----vvvv
  153.           --------vvvveeeerrrrbbbboooosssseeee
  154.                Write an extra output file containing verbose
  155.                descriptions of the parser states and what is done for
  156.                each type of look-ahead token in that state.
  157.  
  158.                This file also describes all the conflicts, both those
  159.                resolved by operator precedence and the unresolved
  160.                ones.
  161.  
  162.                The file's name is made by removing ....ttttaaaabbbb....cccc or ....cccc from
  163.                the parser output file name, and adding ....oooouuuuttttppppuuuutttt
  164.                instead.
  165.  
  166.                Therefore, if the input file is ffffoooooooo....yyyy, then the parser
  167.                file is called ffffoooooooo....ttttaaaabbbb....cccc by default.  As a consequence,
  168.                the verbose output file is called ffffoooooooo....oooouuuuttttppppuuuutttt.
  169.  
  170.           ----VVVV
  171.           --------vvvveeeerrrrssssiiiioooonnnn
  172.                Print the version number of _b_i_s_o_n and exit.
  173.  
  174.           ----hhhh
  175.           --------hhhheeeellllpppp
  176.                Print a summary of the options to _b_i_s_o_n and exit.
  177.  
  178.           ----yyyy
  179.           --------yyyyaaaacccccccc
  180.           --------ffffiiiixxxxeeeedddd----oooouuuuttttppppuuuutttt----ffffiiiilllleeeessss
  181.                Equivalent to ----oooo yyyy....ttttaaaabbbb....cccc; the parser output file is
  182.                called yyyy....ttttaaaabbbb....cccc, and the other outputs are called
  183.                yyyy....oooouuuuttttppppuuuutttt and yyyy....ttttaaaabbbb....hhhh.  The purpose of this switch is to
  184.                imitate _y_a_c_c's output file name conventions.  Thus, the
  185.                following shell script can substitute for _y_a_c_c:
  186.  
  187.                bbbbiiiissssoooonnnn ----yyyy $$$$****
  188.  
  189.  
  190.           The long-named options can be introduced with `+' as well as
  191.           `--', for compatibility with previous releases.  Eventually
  192.  
  193.  
  194.  
  195.      Page 3                                          (printed 4/30/98)
  196.  
  197.  
  198.  
  199.  
  200.  
  201.  
  202.      BBBBIIIISSSSOOOONNNN((((1111))))              UUUUNNNNIIIIXXXX SSSSyyyysssstttteeeemmmm VVVV ((((llllooooccccaaaallll))))              BBBBIIIISSSSOOOONNNN((((1111))))
  203.  
  204.  
  205.  
  206.           support for `+' will be removed, because it is incompatible
  207.           with the POSIX.2 standard.
  208.  
  209.      FFFFIIIILLLLEEEESSSS
  210.           /usr/local/lib/bison.simple   simple parser
  211.           /usr/local/lib/bison.hairy    complicated parser
  212.  
  213.      SSSSEEEEEEEE AAAALLLLSSSSOOOO
  214.           _y_a_c_c(1)
  215.           The _B_i_s_o_n _R_e_f_e_r_e_n_c_e _M_a_n_u_a_l, included as the file
  216.           bbbbiiiissssoooonnnn....tttteeeexxxxiiiinnnnffffoooo in the _b_i_s_o_n source distribution.
  217.  
  218.      DDDDIIIIAAAAGGGGNNNNOOOOSSSSTTTTIIIICCCCSSSS
  219.           Self explanatory.
  220.  
  221.  
  222.  
  223.  
  224.  
  225.  
  226.  
  227.  
  228.  
  229.  
  230.  
  231.  
  232.  
  233.  
  234.  
  235.  
  236.  
  237.  
  238.  
  239.  
  240.  
  241.  
  242.  
  243.  
  244.  
  245.  
  246.  
  247.  
  248.  
  249.  
  250.  
  251.  
  252.  
  253.  
  254.  
  255.  
  256.  
  257.  
  258.  
  259.  
  260.  
  261.      Page 4                                          (printed 4/30/98)
  262.  
  263.  
  264.  
  265.